package org.jivesoftware.smackx.workgroup.util;

import java.util.Iterator;
import java.util.ListIterator;

class ReverseListIterator
  implements Iterator
{
  private ListIterator _i;

  ReverseListIterator(ListIterator paramListIterator)
  {
    this._i = paramListIterator;
    while (true)
    {
      if (!(this._i.hasNext()))
        return;
      this._i.next();
    }
  }

  public boolean hasNext()
  {
    return this._i.hasPrevious();
  }

  public Object next()
  {
    return this._i.previous();
  }

  public void remove()
  {
    this._i.remove();
  }
}